package me.hellp.helloworld.design.flyweight;

/**
 * 数学课，会记录选修的学生
 * 
 * @author linxm
 *
 */
public class MathClass {
	private Integer classId;
	
	private String className;

	public Integer getClassId() {
		return classId;
	}

	public void setClassId(Integer classId) {
		this.classId = classId;
	}

	public String getClassName() {
		return className;
	}

	public void setClassName(String className) {
		this.className = className;
	}
	
	private FlyWeight[] students;

	public FlyWeight[] getStudents() {
		return students;
	}

	public void setStudents(FlyWeight[] students) {
		this.students = students;
	}
	
	public void showStudents(){
		for(int i=0 ;i<this.students.length; i++){
			this.students[i].show();
		}
	}
}
